<HTML><HEAD><TITLE>lp_add_constraints(+Handle, +Constraints, ++Integers)</TITLE>
</HEAD><BODY>[ <A HREF="index.html">library(eplex)</A> | <A HREF="../../index.html">Reference Manual</A> | <A HREF="../../fullindex.html">Alphabetic Index</A> ]
<H1>lp_add_constraints(+Handle, +Constraints, ++Integers)</H1>
Add new constraints to the solver Handle, possibly triggering it.
<DL>
<DT><EM>Handle</EM></DT>
<DD>Handle to a solver state
</DD>
<DT><EM>Constraints</EM></DT>
<DD>A (possibly empty) list of equality or inequality constraints
</DD>
<DT><EM>Integers</EM></DT>
<DD>A (possibly empty) list of variables to be considered as integers in the problem
</DD>
</DL>
<H2>Description</H2>
<P>
  Add new constraints (with possibly new variables) to a solver.
  NewIntegers is a list of variables that the external solver should
  consider as integers  The new constraints will be taken into
  account the next time the solver is run: if the new_constraint option of
  lp_demon_setup was turned on, then the solver will be invoked after the
  adding of the constraints, unless they are already satisfied.  The 
  constraints will be removed on backtracking.
</P><P>
  The constraints are normalised and simplified before being passed to
  the external solver. If any constraint is ground, they are tested for
  consistency.
</P><P>
  Note that variables in NewIntegers can be any problem variables. In
  previous versions of ECLiPSe, there was a restriction that the variables
  be new problem variables; this restriction has been removed.
</P><P>

 </P>
<H3>Fail Conditions</H3>
Any ground (no variable) or bound constraints (one variable) is self-inconsistent.
<H3>Resatisfiable</H3>
no
<H3>Exceptions</H3>
<DL>
<DT><EM>(4) instantiation fault </EM>
<DD>Handle, Constraints or Integers uninstantiated.
<DT><EM>(5) type error </EM>
<DD>Some constraint in Constraints is non-linear.
<DT><EM>(40) stale object handle </EM>
<DD>Handle not valid: solver state had been destroyed by cleanup
</DL>
<H2>See Also</H2>
<A HREF="../../lib/eplex/lp_demon_setup-5.html">lp_demon_setup / 5</A>, <A HREF="../../lib/eplex/lp_add-3.html">lp_add / 3</A>, <A HREF="../../lib/eplex/lp_add_constraints-4.html">lp_add_constraints / 4</A>, <A HREF="../../lib/eplex/eplex_add_constraints-2.html">eplex_add_constraints / 2</A>, <A HREF="../../lib/eplex/SE-2.html">$= / 2</A>, <A HREF="../../lib/eplex/SEL-2.html">$=< / 2</A>, <A HREF="../../lib/eplex/SGE-2.html">$>= / 2</A>, <A HREF="../../lib/eplex/ENE-2.html">=:= / 2</A>, <A HREF="../../lib/eplex/EL-2.html">=< / 2</A>, <A HREF="../../lib/eplex/GE-2.html">>= / 2</A>
</BODY></HTML>
